str = input("请输入字符串:")

def reverse(s):
    if s == "":
        return s
    else:
        return reverse(s[1:]) + s[0]

def letters(toE):
    restr=""
    for i in toE:
        if i.isalpha():
            restr = restr + i
        else:
            continue
    # restr="".join(i for i in toE if i.isalpha())
    return restr

print("剔除非英文字母的字符再将字符串进行反转输出为：{}".format(reverse(letters(str))))
